package com.gitee.huanminabc.jlambda_sql.warapper;

import com.gitee.huanminabc.jlambda_sql.SQL;
import com.gitee.huanminabc.jlambda_sql.SqlWrapper;

/**
 * 简要描述
 *
 * @Author: huanmin
 * @Date: 2025/4/6 12:18
 * @Version: 1.0
 * @Description: 文件作用详细描述....
 */
public class DefaultWrapper<T ,Children extends SqlWrapper>  implements SqlWrapper {
    protected final Children children = (Children) this; //对象本身
    protected   LambdaWrapper<T> typedThis;

    public DefaultWrapper(LambdaWrapper<T> typedThis) {
        this.typedThis = typedThis;
    }

    @Override
    public SQL SQL() {
        return typedThis.SQL();
    }

    @Override
    public void clear() {
        typedThis.clear();
    }

    @Override
    public String getSqlSegment() {
        return typedThis.getSqlSegment();
    }

    @Override
    public String sql() {
        return typedThis.sql();
    }

    @Override
    public Object[] params() {
        return typedThis.params();
    }
}
